'''
Created on 5 Dec 2009

@author: jd437
'''
import GenArrayListY
import GenPrimY

GenPrim=GenPrimY.GenPrim
GenArrayList=GenArrayListY.GenArrayList

ticklength=500
tickheight=1500
tickgap=1000

def GenMarkerTicksH(xoffset,yoffset,ticks,array):
    minimarker=GenPrim(array.markermakeup[0],array.markermakeup[0],0,0,0,'bar')
    marker=[]
    
    #generate the ticks, offset down the marker 
    for i in range(0,ticks):
        marker.extend(GenArrayList(minimarker, xoffset+(tickgap+ticklength)*i,yoffset-tickheight, 0,array.markermakeup[1],array.markermakeup[1],ticklength,tickheight))
        
    #generate the 'bar' of the marker from an array of smaller particles which will transfer.
    marker.extend(GenArrayList(minimarker, xoffset,+yoffset, 0,array.markermakeup[1],array.markermakeup[1],array.markersize[0],array.markersize[1]))

    return marker

def GenMarkerTicksV(xoffset,yoffset,ticks,array):
    minimarker=GenPrim(array.markermakeup[0],array.markermakeup[0],0,0,0,'bar')
    marker=[]
    
    #generate the 'bar' of the marker from an array of smaller particles which will transfer.
    marker.extend(GenArrayList(minimarker, xoffset,+yoffset, 0,array.markermakeup[1],array.markermakeup[1],array.markersize[1],array.markersize[0]))
    #generate the ticks, offset down the marker 
    for i in range(0,ticks):
        marker.extend(GenArrayList(minimarker, xoffset+array.markersize[1]+array.markermakeup[1],+yoffset+i*(ticklength+tickgap), 0,array.markermakeup[1],array.markermakeup[1],tickheight,ticklength))
        
    return marker